//表格表头样式
.ant-table-wrapper {
  //表格 + 分页
  & + .ant-pagination {
    margin-top: 20px;
  }
  thead {
    tr {
      th {
        color: #111d37;
        white-space: nowrap;
        background: rgb(230, 236, 251) !important;
        font-weight: bolder !important;

        i.anticon {
          color: rgba(17, 29, 55, 0.3);
          &:hover,
          &.ant-table-filter-open {
            background: rgb(211, 223, 253) !important;
          }
        }
      }
    }
  }
  tbody {
    tr {
      &:hover {
        background-color: rgba(47, 107, 255, 0.05) !important;
      }
      td {
        &.ant-table-column-sort {
          background: none;
        }
        button {
          height: 22px;
        }
        color: #111d37;
        white-space: nowrap;
        border-bottom-color: rgba(47, 107, 255, 0.1);
      }
    }
  }
  /*.ant-table-filter-selected {
    background-color: #D3DFFD;
    path {
      color: #326AFF !important;
    }
  }*/
  //兼容safari没有自动添加padding-bottom: 0的场景
  .ant-table-fixed-header .ant-table-scroll .ant-table-header {
    padding-bottom: 0;
  }
}

.ant-pagination {
  text-align: center;
}

.customTable {
  .ant-table-scroll {
    .ant-table-header {
      margin-bottom: 0px !important;
      overflow: hidden !important;
      /**
      使用customTable，若接口数据较多，在表格同步前，会出现整个内容区的滚动条，
      以此为基础计算的需要单屏显示的表格表头右侧会缺失一个滚动条宽度的显示区域
      给表格的wrapper增加背景色，修复此问题
       */
      background: rgb(230, 236, 251) !important;
      opacity: 1;
      table {
        min-width: unset;
      }
    }
    .ant-table-body {
      margin-bottom: 0px !important;
      overflow-y: auto !important;
      table {
        min-width: unset;
      }
    }
  }
  .sourceTable {
    height: 0px;
    overflow: hidden;
  }
  .targetTable {
    .ant-table-header table {
      will-change: transfrom;
    }
    &.tbody-min-height {
      .ant-table-body {
        /*最小显示一行*/
        min-height: 56px;
      }
    }
    &.table-no-data {
      .ant-table-placeholder {
        border: none;
      }
    }
    &.table-scroll-x {
      .ant-table-scroll {
        overflow-x: auto;
        overflow-y: hidden;
        background: #ffffff;
        .ant-table-header {
          display: inline-block;
          margin-bottom: -5px !important;
        }
      }
    }
    &.tbody-has-next {
      .ant-table-body {
        tbody tr {
          cursor: pointer;
        }
      }
    }
    &.table-no-max-height {
      table {
        table-layout: auto;
      }
    }
    table {
      table-layout: fixed;
    }
  }
}

.filter-input-wrapper {
  padding: 10px;
  .filter-input {
    width: 188px;
    margin-bottom: 8px;
    display: block;
  }
  .filter-btn-wrapper {
    display: flex;
    justify-content: space-between;
    button {
      width: 90px;
    }
  }
}

.multi-select-wrapper {
  padding: 10px;
  .multi-select {
    width: 188px;
    display: block;
  }
  .filter-btn-wrapper {
    margin-bottom: 8px;
    button {
      width: 90px;
      & + button {
        margin-left: 8px;
      }
    }
  }
}
